﻿using AnesSystem.Services;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;

namespace AnesSystem.Controls.Operation.CQ.CQFY
{
    /// <summary>
    /// AnesRecordBaseInfoCtrl.xaml 的交互逻辑
    /// </summary>
    public partial class AnesRecordBaseInfoCtrl : UserControl
    {
        public AnesRecordBaseInfoCtrl()
        {
            InitializeComponent();
            this.Loaded += AnesRecordBaseInfoCtrl_Loaded;
            //zq.ValueChanged += zq_ValueChanged;
           // jz.ValueChanged += jz_ValueChanged;
           
            InitRadioButton();
        }

        private void InitRadioButton()
        {
            new RadioButtonHelper().ChangeRadioSatus(jsf,jss);
            new RadioButtonHelper().ChangeRadioSatus(fjhss, fjhssf);
            new RadioButtonHelper().ChangeRadioSatus(zq, jz);
           
        }

        private void AnesRecordBaseInfoCtrl_Loaded(object sender, RoutedEventArgs e)
        {
            DateTime ssrqda = DataManager.Instance.CurrentPatientLink.Status.InRoomTime;
            string date = Convert.ToDateTime(ssrqda).ToString("yyyy-MM-dd");
            ssrq.Text = date;
            bool fjhuecsstrue = DataManager.Instance.CurrentPatientLink.AnesthesiaRecord.Fjhss;
            if (fjhuecsstrue)
            {
                DataManager.Instance.CurrentPatientLink.QualityPojo.Fjhecss = true;
            }
           
        }
      

      

       
        
        
    }

}
